package deposit.main;

public class ThreadTest implements Runnable {
   private ListDeposits listDeposits;
   private int index;

    @Override
    public synchronized void run() {
	listDeposits.add100(2);	
    }

    public ListDeposits getListDeposits() {
        return listDeposits;
    }

    public void setListDeposits(ListDeposits listDeposits) {
        this.listDeposits = listDeposits;
    }

    public int getIndex() {
        return index;
    }

    public void setIndex(int index) {
        this.index = index;
    }

    public double getSum(){
	return listDeposits.getSum(index);
}
}
